/*!
 * \file StreamWriter.h
 * \date 12-7-2012 16:01:38
 * 
 * 
 * \author zjhlogo (zjhlogo@gmail.com)
 */
#ifndef __STREAMWRITER_H__
#define __STREAMWRITER_H__

#include <vector>

class StreamWriter
{
public:
	enum CONST_DEFINE
	{
		BLOCK_ALIGN = 128,
	};

	typedef std::vector<unsigned char> TV_UCHAR;

public:
	StreamWriter();
	virtual ~StreamWriter();

	bool write(const void* pData, int nSize);
	bool write(int nPos, const void* pData, int nSize);

	void reset();
	const void* getBuffer();
	int getBufferSize();

private:
	TV_UCHAR m_vBuffer;
	int m_nPos;

};
#endif // __STREAMWRITER_H__
